package com.bbva.general.listeners;

import javax.servlet.ServletConfig;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;

import org.springframework.web.context.support.WebApplicationContextUtils;

import com.bbva.general.util.ServiceContextSpring;

/**
 * Servlet implementation class StartServlet
 */
public class StartServlet extends HttpServlet {
	private static final long serialVersionUID = 1L;
       
    /**
     * @see HttpServlet#HttpServlet()
     */
    public StartServlet() {
        super();
        // TODO Auto-generated constructor stub
    }

    public void init(ServletConfig config) throws ServletException {
    	ServiceContextSpring.initContext( WebApplicationContextUtils.getWebApplicationContext(config.getServletContext()));
    	System.out.println("Inicia contexto DAO..");
    	super.init(config);
    }

}
